<div class="form">
<?php echo $this->Form->create('Absensi'); ?>
   <fieldset>
      <legend>Penjadwalan Karyawan</legend>
      <?php echo $this->Form->input('Foo.jadwal_kerja_id',array('options' => $jadwal_kerja_list, 'empty' => '--- pilih jadwal kerja ---')); ?>
      <?php echo $this->Form->input('Foo.assign_mode',array('type' => 'radio', 'options' => $radio_choice, 'legend' => 'Tipe set jadwal')); ?>
      <?php echo $this->Form->input('Foo.divisi_id',array('options' => $divisi_list, 'empty' => '--- pilih divisi ---')); ?>
      
      <div id="karyawan_list">
         <?php if (($submitted == 'no') && ($assign_mode == 'null')) { ?>
         
         <fieldset id="pilih_karyawan_fieldset" style="display:none;">
            <legend id="pilih_karyawan_legend" style="display:none;">Pilih Karyawan</legend>
            <?php echo $this->Form->input('Foo.karyawan_id',array('options' => $karyawan_list, 'multiple' => true, 'label' => 'Daftar nama karyawan', 'style' => 'display:none;')); ?>
         </fieldset>
         
         <?php } else if (($submitted == 'yes') && ($assign_mode == 'some')) { ?>
         
         <fieldset id="pilih_karyawan_fieldset">
            <legend id="pilih_karyawan_legend">Pilih Karyawan</legend>
            <?php echo $this->Form->input('Foo.karyawan_id',array('options' => $karyawan_list, 'multiple' => true,'label' => 'Daftar nama karyawan'));  ?>
         </fieldset>
         
         <?php } else { ?>
         <fieldset id="pilih_karyawan_fieldset" style="display:none;">
            <legend id="pilih_karyawan_legend" style="display:none;">Pilih Karyawan</legend>
            <?php echo $this->Form->input('Foo.karyawan_id',array('options' => $karyawan_list, 'multiple' => true, 'label' => 'Daftar nama karyawan', 'style' => 'display:none;')); ?>
         </fieldset>
         
         <?php } ?>
      </div>
      
   </fieldset>
   
<?php echo $this->Form->end(__('Simpan',true)); ?>
</div>
<?php echo $javascript->link('/js/absensi/karyawan_jadwal_kerja_pembuatan_page'); ?>